<!-- 为reactive()标注类型 -->
<script lang="ts" setup>
import { reactive } from 'vue'
const book = reactive({ title: '2' })

interface Book {
  title: string
  year?: number
}

const book1: Book = reactive({ title: 'vue 3 指引' })
</script>

<template>
  <div>book:{{ book }}</div>
  <div>book1:{{ book1 }}</div>
</template>

<style lang="scss" scoped></style>
